package com.cyandpos.pad.netdata;

import com.cyandpos.pad.posdata.CodedCouponItem;
import com.cyandpos.pad.posdata.CzkCardItem;
import com.cyandpos.pad.posdata.Payment;
import com.cyandpos.pad.posdata.YhkCardItem;
import com.cyandpos.pad.posdata.YhqCardItem;

import java.util.ArrayList;
import java.util.List;

public class P_Commit {
    private String storeCode;
    private String sktno;
    private String ddly;//单据来源  0 大POS    1安卓POS
    private String ddlx;//单据类型   0 销售     1退货
    private String orderNo;
    private String memberIdToGrantVoucher;//返券会员id
    private String memberIdToReturnVoucher;//退券会员id
    private List<CzkCardItem> czkCard;//储值卡列表
    private List<YhqCardItem> yhqCard;//优惠券列表
    private List<CodedCouponItem> bmqCard;//编码券列表
    public List<Payment> payList;//付款方式列表
    public List<YhkCardItem> yhkCard;// 银行卡列表


    public P_Commit(){
        czkCard = new ArrayList<>();
        yhqCard = new ArrayList<>();
        bmqCard = new ArrayList<>();
        payList = new ArrayList<>();
        yhkCard = new ArrayList<>();
    }

    public List<Payment> getPayList() {
        return payList;
    }

    public void setPayList(List<Payment> payList) {
        this.payList = payList;
    }

    public List<YhkCardItem> getYhkCard() {
        return yhkCard;
    }

    public void setYhkCard(List<YhkCardItem> yhkCard) {
        this.yhkCard = yhkCard;
    }

    public String getStoreCode() {
        return storeCode;
    }

    public void setStoreCode(String storeCode) {
        this.storeCode = storeCode;
    }

    public String getSktno() {
        return sktno;
    }

    public void setSktno(String sktno) {
        this.sktno = sktno;
    }

    public String getDdly() {
        return ddly;
    }

    public void setDdly(String ddly) {
        this.ddly = ddly;
    }

    public String getDdlx() {
        return ddlx;
    }

    public void setDdlx(String ddlx) {
        this.ddlx = ddlx;
    }

    public String getOrderNo() {
        return orderNo;
    }

    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo;
    }

    public String getMemberIdToGrantVoucher() {
        return memberIdToGrantVoucher;
    }

    public void setMemberIdToGrantVoucher(String memberIdToGrantVoucher) {
        this.memberIdToGrantVoucher = memberIdToGrantVoucher;
    }

    public String getMemberIdToReturnVoucher() {
        return memberIdToReturnVoucher;
    }

    public void setMemberIdToReturnVoucher(String memberIdToReturnVoucher) {
        this.memberIdToReturnVoucher = memberIdToReturnVoucher;
    }

    public List<CzkCardItem> getCzkCard() {
        return czkCard;
    }

    public void setCzkCard(List<CzkCardItem> czkCard) {
        this.czkCard = czkCard;
    }

    public List<YhqCardItem> getYhqCard() {
        return yhqCard;
    }

    public void setYhqCard(List<YhqCardItem> yhqCard) {
        this.yhqCard = yhqCard;
    }

    public List<CodedCouponItem> getBmqCard() {
        return bmqCard;
    }

    public void setBmqCard(List<CodedCouponItem> bmqCard) {
        this.bmqCard = bmqCard;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("{");
        sb.append("\"storeCode\":\"")
                .append(storeCode).append('\"');
        sb.append(",\"sktno\":\"")
                .append(sktno).append('\"');
        sb.append(",\"ddly\":\"")
                .append(ddly).append('\"');
        sb.append(",\"ddlx\":\"")
                .append(ddlx).append('\"');
        sb.append(",\"orderNo\":\"")
                .append(orderNo).append('\"');
        sb.append(",\"memberIdToGrantVoucher\":\"")
                .append(memberIdToGrantVoucher).append('\"');
        sb.append(",\"memberIdToReturnVoucher\":\"")
                .append(memberIdToReturnVoucher).append('\"');
        sb.append(",\"czkCard\":")
                .append(czkCard);
        sb.append(",\"yhqCard\":")
                .append(yhqCard);
        sb.append(",\"bmqCard\":")
                .append(bmqCard);
        sb.append('}');
        return sb.toString();
    }

}
